package com.singfan.manage.vm;


import com.singfan.manage.vm.partial.OrderItem;

import java.util.List;

/**
 * Author: hansonghe
 * Date: 2015-10-14 15:07
 * Desc:
 */
public class OrderListModel extends ViewModelBase {
    private String orderList;

    public String getOrderList() {
        return orderList;
    }

    public void setOrderList(String orderList) {
        this.orderList = orderList;
    }

    public static OrderListModel orderItemList2OrderListModel(List<OrderItem> orderItemList){
        OrderListModel orderListModel = new OrderListModel();

        StringBuffer orderListBuffer = new StringBuffer();
        for (OrderItem item : orderItemList){
            orderListBuffer.append(item.toString());
        }

        orderListModel.setOrderList(orderListBuffer.toString());

        return orderListModel;
    }


}
